﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace ZR.Model.Models.ProductionControl {
    /// <summary>
    /// 报警记录
    /// </summary>
    [SugarTable("cks_alarm_rec")]
    [Table(Name = "cks_alarm_rec")]
    public class CksAlarmRecord : BaseEntity {
        /// <summary>
        /// Id 
        /// </summary>
        [SugarColumn(IsPrimaryKey = true, IsIdentity = true)]
        [Column(IsPrimary = true, IsIdentity = true)]
        public long Id { get; set; }

        /// <summary>
        /// PLCID 
        /// </summary>
        public int PlcID { get; set; }

        /// <summary>
        /// 数据块
        /// </summary>
        public int BlockAddr { get; set; }

        /// <summary>
        /// 报警地址
        /// </summary>
        public int AlarmAddr { get; set; }

        /// <summary>
        /// 报警地址位
        /// </summary>
        public int AlarmBitIndex { get; set; }

        /// <summary>
        /// 值
        /// </summary>
        public bool Value { get; set; }

        /// <summary>
        /// 开始时间
        /// </summary>
        public DateTime StartTime { get; set; }

        /// <summary>
        /// 结束时间
        /// </summary>
        public DateTime? EndTime { get; set; }

    }
}
